//==========================================================================
// Copyright (c) 2000-2008,  Elastos, Inc.  All Rights Reserved.
//==========================================================================
#ifndef __POWERFUNC_H__
#define __POWERFUNC_H__

#ifdef  __cplusplus
extern "C" {
#endif

#define MaxDevice 10

//imp by platform related dm to update device power and send to display,
//infact just for emulator,for target cpu,give a null imp
void Power_UpdateDevicePower(int DeviceID,unsigned long Mode);

//imp by platform related scalar
int Scalar_Initialize();
void Scalar_ChangeCpuMode(unsigned long NewMode);
unsigned long Scalar_GetCpuMode();
//to send device power information to display.
void Scalar_SendDevicePower(void * pBuffer,int index);
unsigned long Scalar_GetCpuPower(unsigned long Mode);

//imp by platform related profiler
int  Profiler_Initialize();
int Profiler_GetCpuUsage();

//imp by platform related dm,to decide if to adjust frequency for cpu
bool RunFullSpeed();

//imp by platform related dm,to initialize object such as mutex or event,
//callback function etc.
int Power_Initialize();

#ifdef  __cplusplus
}
#endif

#endif//__POWERFUNC_H__
